﻿
//浏览搜索
function SearBrowseDocs()
{
    var MinPrice=$("selPrice").value.split('-')[0];
    var MaxPrice=$("selPrice").value.split('-')[1];
    var re = /^[\d]{1,9}.?[\d]{0,2}$/gi;    
    if(MinPrice!=""&&MinPrice.search(re) == -1)MinPrice="";    
    if(MaxPrice!=""&&MaxPrice.search(re) == -1)MaxPrice="";
    var ttype="";
    if($("chbTeach").checked && $("chbTutor").checked)
    {
        ttype=3;
    }
    else if($("chbTeach").checked){
        ttype=1;
    }else if($("chbTutor").checked){
        ttype=2;
    }
    
    var isFree = $("IsFreeID").checked?"1":"0";
    var isNativeBL=$("IsNativeBLID").checked?"1":"0";
    top.location="/teacher/1-"+ttype+"-"+$("selTeachL").value+"-"+$("selSpeakL").value+"-"+$("selCountry").value+"-"+MinPrice+"-"+MaxPrice+"-"+isFree+"-"+isNativeBL+"-"+SortBy+".htm"; 
}
//根据昵称名会员号搜索
function SearchDocs()
{
    showProgressBar(true);    
    var searchVal = $("textSear2").value;     
    if(searchVal==null||searchVal=="")
    {       
        showProgressBar(false);
        return;
    }
    if(searchVal>50)searchVal=searchVal.substring(0,49);
    top.location="/teach/search.htm?name="+searchVal+"&sort="+SortBy;
}